package com.springday3aoptransaction;

import com.springday3aoptransaction.config.SpringConfig;
import com.springday3aoptransaction.domain.Account;
import com.springday3aoptransaction.service.AccountService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

import java.io.IOException;
import java.util.List;

public class App {
    public static void main(String[] args) throws IOException {
        ApplicationContext ctx = new AnnotationConfigApplicationContext(SpringConfig.class);

        AccountService accountService = ctx.getBean(AccountService.class);
        accountService.transfer("Tom", "Jerry", 100.00);
    }
}
